﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using ExpertSMS.Models;

namespace ExpertSMS
{
    public class HtmlHelper
    {
        public string ShowChildUnit(Unit unit)
        {
            string result = "";
            result += unit.Name;

                foreach (var childUnit in unit.ChildUnits)
                {
                    result += "<dd>";
                    result += ShowChildUnit(childUnit);
                    result += "</dd>";
                }
            return result;
        }
    }
}